<%--
  Created by IntelliJ IDEA.
  User: Wonderming
  Date: 2018/4/16
  Time: 10:52
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false" %>
<link type="text/css" rel="stylesheet" href="css/common/common.css"/>

<div class="animated fadeInRight">
    <div class="wrapper wrapper-content ng-scope">
         <div class="row">
             <div class="col-lg-12">
                 <div class="ibox float-e-margins">
                      <div class="ibox-title">
                          <h5>{{ 'REFUSED' | translate }}</h5>
                      </div>
                      <div class="ibox-content sk-loading" ng-controller="riskRefusedCtrl">
                          <div class="sk-spinner sk-spinner-wave">
                              <div class="sk-rect1"></div>
                              <div class="sk-rect2"></div>
                              <div class="sk-rect3"></div>
                              <div class="sk-rect4"></div>
                              <div class="sk-rect5"></div>
                          </div>
                          <form name="myform" serializer="searchRefused(data)">
                               <div class="row">
                                   <!--类型-->
                                   <div class="col-sm-6 col-md-4 col-lg-1-5">
                                       <div class="form-group form-group-sm">
                                           <div class="input-group">
                                               <span class="input-group-addon">类型：</span>
                                               <select id="refused_type" name="refused_type" class="form-control" ng-model="refused.refTypeName">
                                                   <option value=""></option>
                                                   <option value="通用">通用</option>
                                                   <option value="收单机构">收单机构</option>
                                                   <option value="商户">商户</option>
                                                   <option value="域名">域名</option>
                                               </select>
                                           </div>
                                       </div>
                                   </div>
                                   <!--名称-->
                                   <div class="col-sm-6 col-md-4 col-lg-1-5">
                                       <div class="form-group form-group-sm">
                                           <div class="input-group" ng-show="refused.refTypeName != '通用' && refused.refTypeName != '收单机构' && refused.refTypeName != '商户' && refused.refTypeName != '收单机构' && refused.refTypeName != '域名'">
                                               <span class="input-group-addon">名称: </span>
                                               <select class="form-control" ng-model="refused.refName">
                                               </select>
                                           </div>
                                           <div class="input-group" ng-show="refused.refTypeName == '通用'">
                                               <span class="input-group-addon">名称: </span>
                                               <select class="form-control" ng-model="refused.refName">
                                                   <option value="">{{ Name }}</option>
                                               </select>
                                           </div>
                                           <div class="input-group" ng-show="refused.refTypeName == '收单机构'">
                                               <span class="input-group-addon">名称: </span>
                                               <select class="form-control" ng-model="refused.refName" ng-options="x.name as x.name for x in init.acquirer">
                                                   <option value="">{{ Name }}</option>
                                               </select>
                                           </div>
                                           <div class="input-group" ng-show="refused.refTypeName == '商户'">
                                               <span class="input-group-addon">名称: </span>
                                               <select class="form-control" ng-model="refused.refName" ng-options="x.name as x.id + '(' + x.name + ')' for x in init.merchant">
                                                    <option value="">{{ Name }}</option>
                                               </select>
                                           </div>
                                           <div class="input-group" ng-show="refused.refTypeName == '域名'">
                                               <span class="input-group-addon">名称：</span>
                                               <select  class="form-control" ng-model="refused.refName" ng-options="x.siteUrl as x.siteUrl for x in init.siteurl">
                                                   <option value="">{{ Name }}</option>
                                               </select>
                                           </div>
                                       </div>
                                   </div>
                                   <!--拒绝元素-->
                                   <div class="col-sm-6 col-md-4 col-lg-1-5">
                                       <div class="form-group form-group-sm">
                                           <div class="input-group">
                                               <span class="input-group-addon">拒绝元素：</span>
                                               <select id="refused_element" name="refused_element" class="form-control" ng-model="refused.refuseName">
                                                   <option  value=""></option>
                                                   <option  value="发卡行">发卡行</option>
                                                   <option  value="商务卡">商务卡</option>
                                                   <option  value="国家">国家</option>
                                                   <option  value="IP">IP</option>
                                                   <option  value="邮箱">邮箱</option>
                                                   <option  value="卡号">卡号</option>
                                               </select>
                                           </div>
                                       </div>
                                   </div>
                                   <!--元素键值-->
                                   <div class="col-sm-6 col-md-4 col-lg-1-5">
                                       <div class="form-group form-group-sm">
                                           <div class="input-group">
                                               <span class="input-group-addon">元素键值：</span>
                                               <select id="refused_key" name="refused_key" class="form-control" ng-model="refused.elementName" ng-options="x.name as x.name for x in initRefusedParam">
                                                   <option value="">{{ Namerefused }}</option>
                                               </select>
                                           </div>
                                       </div>
                                   </div>
                                   <!--状态-->
                                   <div class="col-sm-6 col-md-4 col-lg-1-5">
                                       <div class="form-group form-group-sm">
                                           <div class="input-group">
                                               <span class="input-group-addon">状态：</span>
                                               <select id="refused_status" name="refused_status" class="form-control" ng-model="refused.statusName" ng-options="x.name as x.name for x in statusConstant">
                                               </select>
                                           </div>
                                       </div>
                                   </div>
                                   <!--创建人-->
                                   <div class="col-sm-6 col-md-4 col-lg-1-5">
                                       <div class="form-group form-group-sm">
                                           <div class="input-group">
                                               <span class="input-group-addon">创建人：</span>
                                               <input type="text" id="refused_founder" name="refused_founder" class="form-control" ng-model="refused.creator">
                                           </div>
                                       </div>
                                   </div>
                                   <!--最后修改人-->
                                   <div class="col-sm-6 col-md-4 col-lg-1-5">
                                       <div class="form-group form-group-sm">
                                           <div class="input-group">
                                               <span class="input-group-addon">最后修改人：</span>
                                               <input type="text" id="refused_modifier" name="refused_modifier" class="form-control" ng-model="refused.modifier">
                                           </div>
                                       </div>
                                   </div>
                               </div>
                               <div class="row">
                                   <div class="col-sm-6 col-md-6 col-lg-3 col-lg-offset-3">
                                       <button  type="submit" class="btn btn-sm btn-w-m btn-primary pull-right" ng-click="search(refused)">
                                           查询
                                       </button>
                                   </div>
                                   <div class="col-sm-6 col-md-6 col-lg-3">
                                       <button class="btn btn-sm btn-w-m btn-info" ng-click="resetForm()">
                                           重置
                                       </button>
                                   </div>
                               </div>
                          </form>
                          <div class="hr-line-dashed"></div>
                          <button  type="button"  class="btn btn-sm  btn-primary" ng-click="showModal(row,0)">新增</button>
                          <div class="table-responsive">
                              <table ng-table="refusedTable" class="table table-condensed table-striped table-hover table-bordered">
                                  <tr ng-repeat="row in $data">
                                      <td class="text-center" style="line-height: 2" data-title="''">
                                          <input type="checkbox" id="refusedCheckBoxID" ng-model="refusedCheckBox" ng-click="collectSelectRows($event,row.id)"/>
                                      </td>

                                      <td class="text-center" style="line-height: 2" data-title="'名称'">
                                           {{ row.refName }}
                                      </td>

                                      <td class="text-center" style="line-height: 2" data-title="'类型'">
                                           {{ row.refTypeName }}
                                      </td>

                                      <td class="text-center" style="line-height: 2" data-title="'拒绝元素'">
                                            {{ row.refuseName }}
                                      </td>

                                      <td class="text-center" style="line-height: 2" data-title="'元素键值'" >
                                            {{ row.elementName }}
                                      </td>

                                      <td class="text-center" style="line-height: 2" data-title="'状态'" >
                                            {{ row.statusName }}
                                      </td>

                                      <td class="text-center" style="line-height: 2" data-title="'创建人'" >
                                            {{ row.creator }}
                                      </td>

                                      <td class="text-center" style="line-height: 2" data-title="'创建时间'">
                                            {{ row.createTime | date: 'yyyy-MM-dd hh:mm:ss'}}
                                      </td>

                                      <td class="text-center" style="line-height: 2" data-title="'最后修改人'" >
                                            {{ row.modifier }}
                                      </td>

                                      <td class="text-center" style="line-height: 2" data-title="'修改时间'">
                                            {{ row.modifyTime | date: 'yyyy-MM-dd hh:mm:ss' }}
                                      </td>

                                      <td class="text-center" style="line-height: 2" data-title="'备注'" >
                                            {{ row.remark }}
                                      </td>

                                      <td class="text-center" style="line-height: 2;max-width: 100px;" data-title="'操作'">
                                          <refusedrisk-locked></refusedrisk-locked>
                                      </td>
                                  </tr>
                              </table>
                          </div>
                          <my-pagination table-param="refusedTable"></my-pagination>
                          <button class="btn btn-sm btn-primary del-btn marginTop-minus" ng-click="batchDel()" ng-disabled="deleteFlag">删除</button>
                      </div>
                 </div>
             </div>
         </div>
    </div>
</div>

